package timetable.exceptions;

import java.util.Vector;

public class TimeTableParserErrors extends Exception
{
	private static final long serialVersionUID = -7066641124587962095L;
	
	public Vector<InvalidEntryException> errors;
	
	public TimeTableParserErrors(String message)
	{
		super(message);
		errors = new Vector<InvalidEntryException>();
	}
	
	public Vector<InvalidEntryException> getList()
	{
		return errors;
	}
	
	public String getAllErrors()
	{
		String message = "";
		for (InvalidEntryException e : errors) message += "At line " + e.getID() + ": " + e.getMessage() + "\n";
		return message;
	}
}
